package com.bdqn.mapper;

import com.bdqn.pojo.Sys_menu;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Service;

import java.util.List;

public interface Sys_menuMapper {
    List<Sys_menu> selectParentMenuByUid(int userid);

    List<Sys_menu> selectChildMenusByUidAndPid(int userid, int pid);

    @Select("select * from sys_menu where parent_ids is NULL")
    List<Sys_menu> selectParentMenus();

    @Select("select * from sys_menu where parent_ids=#{pid}")
    List<Sys_menu> selectChildMenusByPid(int pid);
}
